-
Notifications
You must be signed in to change notification settings - Fork 8.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[ML] Delayed data test for Anomaly Detection jobs health rule type #107183
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I left three minor suggestions.
x-pack/plugins/ml/public/alerting/jobs_health_rule/register_jobs_health_alerting_rule.ts
Outdated
Show resolved
Hide resolved
x-pack/plugins/ml/public/alerting/jobs_health_rule/register_jobs_health_alerting_rule.ts
Outdated
Show resolved
Hide resolved
Pinging @elastic/ml-ui (:ml) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
UI text LGTM! Thanks!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code LGTM
@alvarezmelissa87 looks like you have some issues with the Kibana configuration, could be SSL related. Let me know if you need some help with the setup |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
minor things, but looking great
x-pack/plugins/ml/server/models/annotation_service/annotation.ts
Outdated
Show resolved
Hide resolved
const job = jobs.find((j) => j.job_id === v.job_id); | ||
const datafeed = datafeeds?.find((d) => d.job_id === v.job_id); | ||
|
||
const jobLookbackInterval = resolveLookbackInterval([job!], [datafeed!]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 this is great.
Get them all in the same query, then filter down appropriately. good stuff.
Small UI thing I found while testing - wildcard doesn't seem to work with prefixes. Screen.Recording.2021-08-04.at.11.01.46.mov |
@qn895 hey! thanks for reviewing. We don't support wildcards for the jobs selection. Just a special case for all jobs (with * symbol) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Helper tooltips LGTM!
Co-authored-by: István Zoltán Szabó <istvan.szabo@elastic.co>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested and LGTM
💚 Build Succeeded
Metrics [docs]Async chunks
History
To update your PR or re-run it, just comment with: cc @darnautov |
…lastic#107183) * [ML] enable test selection * [ML] executor update for annotations * [ML] update unit tests * [ML] fix i18n * [ML] update schema * [ML] fix ts * [ML] account for docs count, update unit tests * [ML] update translation strings * [ML] add types * [ML] fetch the latest annotation sorted by modified_time * [ML] getDelayedDataAnnotations * [ML] update unit tests * [ML] set default number of docs to 1, update schema validation * [ML] getDelayedDataLookbackTimestamp * [ML] filter null values, update unit tests * [ML] account for query delay, refactor with memoize * [ML] update unit test * [ML] remove previousStartedAt * [ML] filter based on the job config * [ML] fix tests * [ML] add maps * [ML] combine filters * [ML] move range query inside of a filter * [ML] filter out jobs with missing datafeed * [ML] resolveLookbackInterval only from jobs with datafeeds * [ML] do not show an error on empty time interval * [ML] add help tooltips * [ML] update description for the datafeed check
💚 Backport successful
This backport PR will be merged automatically after passing CI. |
…107183) (#107762) * [ML] enable test selection * [ML] executor update for annotations * [ML] update unit tests * [ML] fix i18n * [ML] update schema * [ML] fix ts * [ML] account for docs count, update unit tests * [ML] update translation strings * [ML] add types * [ML] fetch the latest annotation sorted by modified_time * [ML] getDelayedDataAnnotations * [ML] update unit tests * [ML] set default number of docs to 1, update schema validation * [ML] getDelayedDataLookbackTimestamp * [ML] filter null values, update unit tests * [ML] account for query delay, refactor with memoize * [ML] update unit test * [ML] remove previousStartedAt * [ML] filter based on the job config * [ML] fix tests * [ML] add maps * [ML] combine filters * [ML] move range query inside of a filter * [ML] filter out jobs with missing datafeed * [ML] resolveLookbackInterval only from jobs with datafeeds * [ML] do not show an error on empty time interval * [ML] add help tooltips * [ML] update description for the datafeed check Co-authored-by: Dima Arnautov <dmitrii.arnautov@elastic.co>
…lastic#107183) * [ML] enable test selection * [ML] executor update for annotations * [ML] update unit tests * [ML] fix i18n * [ML] update schema * [ML] fix ts * [ML] account for docs count, update unit tests * [ML] update translation strings * [ML] add types * [ML] fetch the latest annotation sorted by modified_time * [ML] getDelayedDataAnnotations * [ML] update unit tests * [ML] set default number of docs to 1, update schema validation * [ML] getDelayedDataLookbackTimestamp * [ML] filter null values, update unit tests * [ML] account for query delay, refactor with memoize * [ML] update unit test * [ML] remove previousStartedAt * [ML] filter based on the job config * [ML] fix tests * [ML] add maps * [ML] combine filters * [ML] move range query inside of a filter * [ML] filter out jobs with missing datafeed * [ML] resolveLookbackInterval only from jobs with datafeeds * [ML] do not show an error on empty time interval * [ML] add help tooltips * [ML] update description for the datafeed check
Summary
Part of #101028
Adds the delayed data test for Anomaly Detection jobs health rule type.
Rule executor looks up for
delayed_data
events in the annotations index within the provided time interval.Checklist